﻿using System;
using System.Text;
using System.Collections.Generic;
using System.Linq;
using Microsoft.VisualStudio.TestTools.UnitTesting;

namespace NTTDATA.BEENChina.ResultCertification.Test
{
    [TestClass]
    public class UnitTest1
    {
        [TestMethod]
        public void TestMethod1()
        {
            string imageid = "131231132131001";
            string path = @"c:\a\a\a\a";

            string childPicParam = string.Empty;

            if (imageid.Contains("-") )
                childPicParam = @"\" + imageid.Substring(imageid.IndexOf("-", System.StringComparison.Ordinal)+1);

            string imageFullPath = path;
            if (!String.IsNullOrEmpty(childPicParam))
            {
                  imageFullPath = System.IO.Path.Combine(path, childPicParam);
            }

            imageFullPath = System.IO.Path.Combine(imageFullPath, imageid + ".TIF");

            Console.WriteLine(imageFullPath);


        }
    }
}
